{extend name="Public:base"/}

{block name="main"}
<div class="box-info">
    <form action="{:U('Admin/add')}" method="post">
        <div class="form-group row">
            <label class="col-sm-2 form-control-label">用户名</label>
            <div class="col-xs-4">
                <input type="text" class="form-control" name="username">
            </div>
        </div>
        <div class="form-group row">
            <label class="col-sm-2 form-control-label">密码</label>
            <div class="col-xs-4">
                <input type="password" name="password" class="form-control" />
            </div>
        </div>
        <div class="form-group row">
            <label class="col-sm-2 form-control-label">确认密码</label>
            <div class="col-xs-4">
                <input type="password" name="repassword" class="form-control"/>
            </div>
        </div>
        <div class="form-group row">
            <label class="col-sm-2 form-control-label">邮箱</label>
            <div class="col-xs-4">
                <input type="text" class="form-control" name="email" >
            </div>
        </div>
        <div class="form-group row env-class">
            <label class="col-sm-2 form-control-label">所属角色</label>
            <div class="col-xs-4">
                <select name="group_id" class="form-control">
                    {volist name="groups" id="vo"}
                        <option value="{$vo['id']}">{$vo['name']}</option>
                    {/volist}
                </select>
            </div>
        </div>
        <div class="form-group row">
            <label class="col-sm-2 form-control-label">状态</label>
            <div class="col-xs-4">
                <div class="form-check form-check-inline">
                    <label class="form-check-label">
                        <input class="form-check-input" type="radio" name="status" value="1" checked="checked" />启用
                    </label>
                </div>
                <div class="form-check form-check-inline">
                    <label class="form-check-label">
                        <input class="form-check-input" type="radio" name="status" value="0" />禁用
                    </label>
                </div>
            </div>
        </div>
        <div class="form-actions">
            <div class="col-sm-offset-2">
                <button type="submit" class="btn btn-primary ajax_form_add">提交</button>
                <button type="button" class="btn btn-danger" onclick="javascript:history.back(-1);return false;">返回</button>
            </div>
        </div>
    </form>
</div>

{/block}